﻿using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Net;
using System.Web;
using FaceSharp.Api.Extensions;
using Newtonsoft.Json.Linq;
using RestSharp;

namespace FaceSharp.Api.GraphApi
{
    public class GraphBase : TypedGraphClient<JObject>
    {
        public GraphBase(IFacebookCore facebookCore)
            : base(facebookCore, (rawResults) => (rawResults != null ? JObject.Parse(rawResults) : null))
        {
        }
        
        public JObject GetMetaData(string id)
        {
            return base.GetMetaData(id);
        }

        public JObject MakeGraphPost(
         string id,
         Dictionary<string, string> parameters
         )
        {
            return base.MakeGraphPost(id, parameters);
        }

        public JObject MakeGraphPost(
             string id,
             string connection,
             Dictionary<string, string> parameters
             )
        {
            return base.MakeGraphPost(id,connection,parameters);
        }

        public JObject MakeGraphSeach(
            string query = null,
            string objectType = null
            )
        {
            return base.MakeGraphSeach(query, objectType);
        }

        public JObject MakeGraphRequest(
             string id,
             string connection = null,
             IEnumerable<string> fields = null)
        {
            return base.MakeGraphRequest(id, connection, fields);
        }

        public JObject MakeGraphRequest(
            IEnumerable<string> ids,
            IEnumerable<string> fields = null)
        {
            return base.MakeGraphRequest(ids, fields);
        }
    }
}